package cn.zhqr.common.util.datetime;

import java.text.SimpleDateFormat;
import java.util.Date;


public class TimeUtils {

	public static int getUnixTimeStamp() {
		return(int)( System.currentTimeMillis()/ 1000);
	}
	/**
	 * 返回格式化后的内容, 显示时间
	 * @param timestamp
	 * @return
	 */
	public static String formatUnixTimestamp(int timestamp) {
		SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd hh:mm:ss");
		return sdf.format(  new Date(1000L*timestamp));
	}
}
